/**
 * @Project TMHSC
 * @Author Tran Manh Hung
 * @Email: hungtmit@gmail.com | tmh@xwebgate.com
 * @Copyright © 2011 TMH. All rights reserved
 * @Createdate Feb 25, 2011
 * @Createtime 5:46:53 PM
 */

package com.tmh.study.aS3DP.mcv.minimalist
{
	import flash.events.Event;

	public class CompositeView extends ComponentView
	{
		private var aChildren:Array;

		public function CompositeView(model:Object, controller:Object = null)
		{
			super(model, controller);

			this.aChildren = new Array();
		}

		override public function add(c:ComponentView):void
		{
			aChildren.push(c);
		}

		override public function update(event:Event = null):void
		{
			for each (var c:ComponentView in aChildren)
			{
				c.update(event);
			}
		}
	}
}